home *** CD-ROM | disk | FTP | other *** search
/ Compendium Deluxe 1 / LSD Compendium Deluxe 1.iso / a / programming / assembly / bbintro.lha / B_Block_Scroll2.s < prev    next >
Encoding:
Text File  |  1980-01-01  |  2.8 KB  |  152 lines

  1. move.l 4,a6
  2. jsr -30-102(a6)
  3.  
  4. move.l #$20000,a1
  5. lea  copperlist,a2
  6.  
  7. cloop:
  8. move.l (a2),(a1)+
  9. cmp.l #$fffffffe,(a2)+
  10. bne  cloop
  11.  
  12. lea.l  $50000,a0
  13. lea.l  $52000,a1
  14. lea.l  $54000,a2
  15. lea.l  $56000,a3
  16.  
  17. move.l #1100,d0
  18. ploop:
  19. clr.w  (a0)+
  20. clr.w  (a1)+
  21. clr.w  (a2)+
  22. clr.w  (a3)+
  23. dbra   d0,ploop
  24.  
  25. move.w #$03e0,$dff096
  26. move.l #$20000,$dff080
  27. move.w #$0000,$dff088
  28. move.w #$83c0,$dff096
  29.  
  30. move.l #text,textpos
  31. move.b #1,rows
  32. move.l $6c,oldirq
  33. move.l #newirq,$6c
  34.  
  35. nomouse: btst #6,$bfe001
  36.          bne  nomouse
  37.  
  38. clr.l  d0
  39. rts
  40.  
  41. newirq:
  42. movem.l d0-d7/a0-a6,-(sp)
  43. move.l #$50000+2200,d0
  44. jsr    scrollplane
  45. move.l #$52000+2200,d0
  46. jsr    scrollplane
  47. move.l #$54000+2200,d0
  48. jsr    scrollplane
  49. move.l #$56000+2200,d0
  50. jsr    scrollplane
  51. move.b rows,d0
  52. subq.b #1,d0
  53. cmp.b  #0,d0
  54. bne    exit
  55.  
  56. jsr    newchar
  57. exit:
  58. move.b  d0,rows
  59. exit2:
  60. movem.l (sp)+,d0-d7/a0-a6
  61. dc.w    $4ef9
  62. oldirq: dc.l 0
  63.  
  64. newchar:
  65. clr.l  d0
  66. move.l textpos,a0
  67. move.b (a0),d0
  68. addi.l #1,textpos
  69. cmp.l  #textend,textpos
  70. bne    noend
  71. move.l #text,textpos
  72. noend:
  73. move.l textpos,a0
  74. cmp.b  #32,d0
  75. bne    nospace
  76. move.b #6,d0
  77. rts
  78. nospace:
  79. sub.l  #33,d0
  80. mulu   #1080,d0
  81. add.l  #chars,d0
  82.  
  83. move.l #$50000+46,d1
  84. jsr    copychar
  85. add.l  #270,d0
  86. move.l #$52000+46,d1
  87. jsr    copychar
  88. add.l  #270,d0
  89. move.l #$54000+46,d1
  90. jsr    copychar
  91. add.l  #270,d0
  92. move.l #$56000+46,d1
  93. jsr    copychar
  94. move.b #6,d0
  95. rts
  96.  
  97. copychar:
  98. btst   #6,$dff002
  99. bne.s  copychar
  100. move.w #$ffff,$dff044
  101. move.w #$ffff,$dff046
  102. move.l d0,    $dff050
  103. move.l d1,    $dff054
  104. move.w #$09f0,$dff040
  105. clr.w         $dff042
  106. clr.w         $dff064
  107. move.w #44,   $dff066
  108. move.w #%0000101101000011,$dff058
  109. rts
  110.  
  111. scrollplane:
  112. btst   #6,$dff002
  113. bne.s  scrollplane
  114. move.l d0,$dff050
  115. move.l d0,$dff054
  116. move.w #$89f0,$dff040
  117. move.w #$0002,$dff042
  118. move.w #$ffff,$dff044
  119. move.w #$00ff,$dff046
  120. clr.w  $dff064
  121. clr.w  $dff066
  122. move.w #%0000101101011001,$dff058
  123. rts
  124.  
  125. rows:  dc.b 0
  126. even
  127. chars: blk.b 62640
  128. copperlist:
  129. dc.w  $00e0,$0005,$00e2,$0002,$00e4,$0005,$00e6,$2002
  130. dc.w  $00e8,$0005,$00ea,$4002,$00ec,$0005,$00ee,$6002
  131. dc.w  $0100,$4200,$0102,$0000,$0104,$0000,$0108,$0006
  132. dc.w  $010a,$0006,$0092,$0030,$0094,$00d8,$008e,$9671
  133. dc.w  $0090,$c2d1,$0180,$0000,$0182,$0fff,$0184,$0000
  134. dc.w  $0186,$0000,$0188,$0000,$018a,$0111,$018c,$0222
  135. dc.w  $018e,$0333,$0190,$0444,$0192,$0555,$0194,$0666
  136. dc.w  $0196,$0777,$0198,$0888,$019a,$0999,$019c,$0aaa
  137. dc.w  $019e,$0bbb
  138. dc.w  $ffff,$fffe
  139.  
  140. text:
  141. DC.B "HEY, FREAKS ! THE MAD BRAINS PRESENTS NEW STUFF ! "
  142. DC.B "GREETINGS TO BAMIGA SECTOR ONE, UNIT A, MEGAFORCE,"
  143. DC.B " D.O.C, POWERSLAVES, VISION FACTORY, WORLD OF WOND"
  144. DC.B "ERS, DEFJAM, STEEL PULSE, HOTLINE, LIGHTCIRCLE, TH"
  145. DC.B "RUST, ALPHA FLIGHT, HQC AND ALL THE OTHERS WE KNOW"
  146. DC.B " ! AND NOW HAVE MUCH FUN AND PRESS THE RED BUTTON "
  147. DC.B "ON YOUR MOUSE ! END OF SCROLLTEXT.....            "
  148. DC.B "                    "
  149. textend:
  150.  even
  151. textpos: dc.l 0
  152.